package org.onvivals.module.ums.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.io.Serial;
import java.io.Serializable;
import java.util.Date;

@Schema(description="用户角色表")
@Data
@TableName(value = "ums_user_role")
public class UmsUserRole implements Serializable {

	@Serial
	private static final long serialVersionUID = 1L;

	/**
	 * 设备ID
	 */
	@TableField(value = "user_id")
	@Schema(description="用户")
	private Long userId;

	/**
	 * 角色ID
	 */
	@TableField(value = "role_id")
	@Schema(description="角色ID")
	private Long roleId;


	/**
	 * 角色ID
	 */
	@TableField(value = "role_name")
	@Schema(description="角色昵称")
	private String roleName;


	/**
	 * 创建人
	 */
	@TableField(value = "create_by")
	@Schema(description="创建人")
	private String createBy;

	/**
	 * 创建时间
	 */
	@TableField(value = "create_time",fill = FieldFill.INSERT)
	@Schema(description="创建时间")
	private Date createTime;

	/**
	 * 更新人
	 */
	@TableField(value = "update_by")
	@Schema(description="更新人")
	private String updateBy;

	/**
	 * 更新时间
	 */
	@TableField(value = "update_time",fill = FieldFill.INSERT_UPDATE)
	@Schema(description="更新时间")
	private Date updateTime;
}
